package com.wanlian.router.ui.main.yun;

import android.os.Bundle;
import android.view.View;
import android.widget.ListView;

import com.smart.android.ui.BaseFragment;
import com.smart.android.utils.FileUtils;
import com.wanlian.router.R;
import com.wanlian.router.bean.UpTask;
import com.wanlian.router.bean.YunFile;

import java.util.ArrayList;
import java.util.List;

import butterknife.BindView;

/**
 * Created by Hyu on 2018/9/23.
 * Email: fvaryu@163.com
 */
public class DownFragment extends BaseFragment {

    @BindView(R.id.view_listview_0)
    ListView view_listview_0;

    List<UpTask> mYunFiles = new ArrayList<>();

    @BindView(R.id.view_listview_1)
    ListView view_listview_1;
    List<UpTask> mYunDoneFiles = new ArrayList<>();


    public static DownFragment newInstance() {
        Bundle args = new Bundle();
        DownFragment fragment = new DownFragment();
        fragment.setArguments(args);
        return fragment;
    }

    @Override
    protected int layout() {
        return R.layout.fragment_down;
    }

    @Override
    protected void initUI(View view) {
        super.initUI(view);

        view_listview_0.setAdapter(new ProgressAdapter(getActivity(), mYunFiles));

        view_listview_1.setAdapter(new ProgressDoneAdapter(getActivity(), mYunDoneFiles));

    }

    @Override
    protected void initData(View view) {
        super.initData(view);

    }
}
